Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

simplify regex and use semver pkg #14

Merged
merged 3 commits into from
Nov 13, 2023

Conversation

micbar
Copy link
Contributor

@micbar micbar commented Nov 10, 2023

Description

We would like to extend the versioning schema by prereleases.

Details

We would like to use semantic versioning like the following examples

  • 1.0.0-beta.11_2023-11-09
  • 1.0.0-rc.1_2023-11-10

Please check the added unit tests. They should confirm that the regex is working.

@micbar
Copy link
Contributor Author

micbar commented Nov 10, 2023

@fd0 Could you take this into consideration?

main.go Outdated Show resolved Hide resolved
go.mod Outdated Show resolved Hide resolved
@micbar micbar force-pushed the add-prereleases branch 3 times, most recently from a2a668d to 4a45f99 Compare November 12, 2023 20:38
@micbar
Copy link
Contributor Author

micbar commented Nov 12, 2023

I see a failing unit test because the testing framework does not know t.TempDir() in go 1.12.

Do we really need to be backwards compatible with go 1.12?

@micbar micbar force-pushed the add-prereleases branch 2 times, most recently from 5245ac9 to bd6f1a7 Compare November 12, 2023 20:57
@MichaelEischer
Copy link
Member

Do we really need to be backwards compatible with go 1.12?

No, that amount of backwards compatibility exists for history reasons. Feel free to bump it to Go 1.15 (added TestDir()) or Go 1.17 (same as rest-server).

Please also update the commit message which no longer matches the changes in the PR.

@micbar micbar changed the title extend regex to allow prereleases simplify regex and use semver pkg Nov 13, 2023
@micbar
Copy link
Contributor Author

micbar commented Nov 13, 2023

@MichaelEischer I implemented your feedback and bumped the min go version to 1.15.

Copy link
Member

@MichaelEischer MichaelEischer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@MichaelEischer MichaelEischer merged commit 4edd6e9 into restic:master Nov 13, 2023
@micbar
Copy link
Contributor Author

micbar commented Nov 13, 2023

Awesome!

together with #12 it could be handy to create a new tag. We are heavily using it in the owncloud organization.

@MichaelEischer
Copy link
Member

MichaelEischer commented Nov 19, 2023

I've tagged a 0.4.0 version: https://github.com/restic/calens/releases/tag/v0.4.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants